<template>
	<div class="zhengtuojianhuo">
		<van-nav-bar :fixed="true" class="navBar" title="已领拣货" left-arrow @click-left="$router.go(-1)"></van-nav-bar>

		<div class="carCardWarp">
			<div class="carCard" v-for="(item,index) in lingquData" :key="index">

				<div class="goodsTitleRow" style="margin-bottom: 10px;">
						<div class="goodsTitleLabel">
							<div class="skuName">序号：</div>
						</div>
						<div class="skuNoTitle">
						{{item.rownum}}
						</div>
				</div>


				<div class="goodsTitleRow" style="margin-bottom: 10px;">
						<div class="goodsTitleLabel">
							<div class="skuName">波次单：</div>
						</div>
						<div class="skuNoTitle">
							{{item.bill}}
						</div>
				</div>

				<div class="goodsTitleRow" >
						<div class="goodsTitleLabel">
							<div class="skuName">任务摘要：</div>
						</div>
						<div class="skuNoTitle">
							{{item.rwdesc}}
						</div>
				</div>
			</div>
		</div>


	</div>
</template>

<script>

export default {
  name: 'yilingjianhuo',
  data() {
    return {
			editForm:{
				jhrqid:'J01333838',
			},
			isdisabled:false,
			lingquData:[],
			isLingQuVisible:false,
			skuData:[],
			isSkuVisible:false,
			index:0,
			skuRow:{},
			timeoutId: null,
			isMessageVisible:false,
			total:0,
			areElementsSame:''
		};
  },
	computed: {
		 ryuser: function(){
			 return this.GWO(true).gUSER;
		 },
	},
  methods: {
		lingquBtn(){
			var _self = this;
			_self.total = 0
			var ldemodata = [{retval:0, errmsg:'返回数据集'},]
			this.MYPOST({
				'method':'dgate',
				'pname':'f_wmsa_y_jianhuo',
				'i':this.FNULLE([
				'opmode','Y_YLJH_qrybill',
				'czyid',this.ryuser.operatorid,
				'kqid', this.ryuser.kqid,
				])
				},'已领拣货查询',true, ldemodata, function(ret_obj, ret_iserr,ret_errmess,ret_oldresp){
				if(ret_iserr){ //传入的true参数,理论上不会有此回调了
					_self.$toast.fail('查询失败')
					_self.$store.commit('hideLoading');
				}else{
					var rtn_json_obj = null;
					_self.$store.commit('hideLoading');
					if(ret_obj != null){ rtn_json_obj = ret_obj; //返回的接口可以直接解析的情况
					}else{  rtn_json_obj = _self.arr2Obj(ret_oldresp.data); //非标准的dgate接口,返回的一个不兼容的处理
					}
					console.log("得到已领拣货查询")
					console.log(rtn_json_obj)
					_self.lingquData = rtn_json_obj
				}
			});
		},
  },
  mounted() {
		this.lingquBtn();
  },
	components: {

	},
};
</script>

<style lang="scss" scoped>
	// 引入公共样式
	@import '@/assets/css/base.scss';
	@import '@/assets/css/input.scss';
	div.zhengtuojianhuo{
		padding-top:40px;
	}



	div.carCardWarp{
		width: 94%;
		margin-left: 3%;
		margin-right: 3%;
		margin-top: 20px;
		font-size: 20px;
		font-weight: bold;
		div.carCard{
			position: relative;
			border-left: 5px solid #4998FF;
			box-sizing: border-box;
			padding-left: 10px;
			padding-right: 10px;
			border-radius:5px;
			background-color: #fff;
			padding-top: 10px;
			padding-bottom: 10px;
			margin-bottom:15px;
			div.status{
				position: absolute;
				right: 0;
				top: 0;
				width: 65px;
				height: 30px;
				display: flex;
				align-items: center;
				justify-content: center;
				color: #fff;
				font-size: 12px;
				border-radius: 0px 10px 0px 10px;
			}
			div.goodRow{
				margin-bottom:8px;
				span{
					display: inline-block;
					width:100px;
				}
			}
			div.goodsTitleRow{
				display: flex;
				width: 100%;
				div.goodsTitleLabel{
					width: 100px;
				}
				div.skuNoTitle{
					width: calc(100% - 100px);
				}
			}
		}
	}
</style>
